Skip to content

Conversation

@guessi
Copy link
Contributor

@guessi guessi commented Oct 8, 2025

  • Add resolveYAMLAnchors() function to process YAML anchors and aliases
  • Remove only 'aliases' field to maintain strict validation for other fields
  • Include security protections against YAML bombs and excessive nesting
  • Add comprehensive test coverage for functionality and edge cases
  • Update FAQ documentation with YAML anchor examples

Fixes #8270

@guessi guessi force-pushed the feature/yaml-anchor-support branch from 457c0e8 to 98d11c5 Compare October 9, 2025 05:58
@guessi guessi force-pushed the feature/yaml-anchor-support branch 3 times, most recently from c6d24ff to 21eb238 Compare October 9, 2025 07:09
@NicholasBlaskey NicholasBlaskey added the kind/feature New feature or request label Oct 9, 2025
- Add resolveYAMLAnchors() function to process YAML anchors and aliases
- Remove only 'aliases' field to maintain strict validation for other fields
- Include security protections against YAML bombs and excessive nesting
- Add comprehensive test coverage for functionality and edge cases
- Update FAQ documentation with YAML anchor examples

Fixes eksctl-io#8270
@guessi guessi force-pushed the feature/yaml-anchor-support branch from 21eb238 to 5152cb6 Compare October 10, 2025 02:57
@guessi
Copy link
Contributor Author

guessi commented Oct 10, 2025

@NicholasBlaskey I've made some changes to the PR, with simplified solution, more test cases and FAQ section added, please review.

Comment on lines +259 to +260
// Remove only the aliases field, maintaining strict validation for everything else
delete(temp, "aliases")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the implementation to support special "aliases" section only.

Comment on lines +219 to +223
// Security: Limit input size to prevent memory exhaustion attacks
const maxInputSize = 1024 * 1024 // 1MB limit
if len(data) > maxInputSize {
return nil, fmt.Errorf("YAML input too large: %d bytes exceeds limit of %d bytes", len(data), maxInputSize)
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

YAML file over 1MB should be considered as abnormal, any concern?

@github-actions github-actions bot added the stale label Nov 14, 2025
@github-actions github-actions bot closed this Nov 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/feature New feature or request stale

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] ClusterConfig to support for YAML anchors and aliases

2 participants